
'use strict';

/**
	Part of Zombie Navigator
	Copyright © 2015  Zombie Navigator Developers
	
	@file
	@license AGPL-3.0+
*/


/* Used modules */
const _modAboutAddon = require('../platform/about-addon');
const _modHelp = require('./help');


/**
	List of preference names (see package.json)
	@private
*/
const {
	PREF_NAME_BUTTON_HELP
	, PREF_NAME_BUTTON_LICENSE
} = require('../pref-names.json');


/**
	Start listening to input
	@public
*/
const acceptInput = () => {
	// 'Help' button
	_modAboutAddon.addButtonHandler(PREF_NAME_BUTTON_HELP, () => {
		const modHelp = _modHelp;
		modHelp.showHelp();
	});
	
	// 'License' button
	_modAboutAddon.addButtonHandler(PREF_NAME_BUTTON_LICENSE, () => {
		const modHelp = _modHelp;
		modHelp.showLicense();
	});
};


/*
	Exports
*/
exports.acceptInput = acceptInput;


// vim: ts=4 noet ai

